package cn.lili.modules.distribution.entity.vos;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * 分销商品信息
 *
 * @author pikachu
 * @since 2020-03-26 09:04:53
 */
@Data
public class DistributionGoodsVO {

    @ApiModelProperty(value = "分销商品ID")
    private String id;

    @ApiModelProperty(value = "商品名称")
    private String goodsName;

    @ApiModelProperty(value = "规格")
    private String specs;

    @ApiModelProperty(value = "库存")
    private Integer quantity;

    @ApiModelProperty(value = "商品图片")
    private String thumbnail;

    @ApiModelProperty(value = "商品价格")
    private Double price;

    @ApiModelProperty(value = "商品编号")
    private String sn;

    @ApiModelProperty(value = "商品ID")
    private String goodsId;

    @ApiModelProperty(value = "规格ID")
    private String skuId;

    @ApiModelProperty(value = "店铺名称")
    private String storeName;

    @ApiModelProperty(value = "佣金金额")
    private Double commission;

    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "添加时间")
    private Date createTime;

    @ApiModelProperty(value = "分销商ID")
    private String distributionId;

    /**
     * 分类path
     */
    @Field(type = FieldType.Text, fielddata = true)
    @ApiModelProperty("子分类path  多个按-分割")
    private String categoryPathSon;
    /**
     * 商品价格
     */
    @Field(type = FieldType.Double)
    @ApiModelProperty("商品价格")
    private Double vipPrice;
    /**
     * 如果是红包商品需要使用的红包
     */
    @Field(type = FieldType.Integer)
    @ApiModelProperty("红包商品需要使用的红包")
    private Integer redPack;
    /**
     * 是否为绿色商品
     */
    @Field(type = FieldType.Boolean)
    @ApiModelProperty("是否为绿色商品")
    private Boolean isGreenGoods;

    @Field(type = FieldType.Double)
    @ApiModelProperty(value = "最大F分抵扣值")
    private Double maxfNumber;
    /**
     * 是否为公益商品
     */
    @Field(type = FieldType.Boolean)
    @ApiModelProperty("是否为公益商品")
    private Boolean isCommonwealGoods;
    /**
     * 是否为公益商品
     */
    @Field(type = FieldType.Boolean)
    @ApiModelProperty("是否为会员商品")
    private Boolean isVipGoods;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty(value = "是否全返商品")
    private Boolean isResultGoods;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty(value = "是否绿色积分卷抵扣")
    private Boolean isGreenSecurities;

    @ApiModelProperty(value = "绿色积分")
    private Double greenScore;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty("是否为盲盒商品")
    private Boolean isMhGoods;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty(value = "是否演唱会门票")
    private Boolean isTicket;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty(value = "是否套餐商品")
    private Boolean isMeal;

    @ApiModelProperty(value = "虚拟购买数量")
    private Integer virtualBuyCount;

    @Field(type = FieldType.Boolean)
    @ApiModelProperty(value = "是否是分销商品")
    private Boolean isDistributionGoods;

}
